BlobをData URIに変換する
/icons/javascript.icon
code:script.js
export function BlobToURI(blob) {
const fileReader = new FileReader();
const promise = new Promise(resolve =>
fileReader.onload = () => resolve(fileReader.result)
);
fileReader.readAsDataURL(blob);
return promise;
}